7 examples for git checkout
# The following command will create a local branch named foo, tracking the remote branch origin/foo. When you push your # changes the remote branch will be updated. git checkout --track origin/foo
# Get the foo.py file from origin develop into the current branch. git checkout origin/develop foo.py
# Selectively checkout part of a file from a different branch git checkout --patch branch_name -- file_name
# Create a local named `foo` based on `origin/bar`, # but do not track `origin/bar`. git checkout --no-track -b foo origin/bar